var e = require;
var t = module;
var n = exports;
"use strict";
var o, i = this && this.__extends || (o = function(e, t) {
        return (o = Object.setPrototypeOf || { __proto__: [] }
            instanceof Array && function(e, t) { e.__proto__ = t } || function(e, t) { for (var n in t) Object.prototype.hasOwnProperty.call(t, n) && (e[n] = t[n]) })(e, t)
    }, function(e, t) {
        function n() { this.constructor = e }
        o(e, t), e.prototype = null === t ? Object.create(t) : (n.prototype = t.prototype, new n)
    }),
    r = this && this.__decorate || function(e, t, n, o) {
        var i, r = arguments.length,
            y = r < 3 ? t : null === o ? o = Object.getOwnPropertyDescriptor(t, n) : o;
        if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) y = Reflect.decorate(e, t, n, o);
        else
            for (var a = e.length - 1; 0 <= a; a--)(i = e[a]) && (y = (r < 3 ? i(y) : 3 < r ? i(t, n, y) : i(t, n)) || y);
        return 3 < r && y && Object.defineProperty(t, n, y), y
    };
Object.defineProperty(n, "__esModule", { value: !0 });
var y, a = e("EventConst"),
    s = e("PlatformConst"),
    c = e("AudioManager"),
    x = e("BmsManager"),
    l = e("EventManager"),
    h = e("LanguageManager"),
    d = e("PlatformManager"),
    u = e("ReportManager"),
    f = e("SceneManager"),
    p = e("CopyRightDialog"),
    g = { zh: 0, en: 1, ja: 1, tw: 2 },
    t = cc._decorator,
    e = t.ccclass,
    t = t.property,
    e = (y = cc.Component, i(m, y), m.prototype.onLoad = function() {
        this.initMgr(), this.initEvent(), (new p.default).init()
    }, m.prototype.initMgr = function() {
        f.Scene.init();
        var e = h.default.instance;
        
        console.error("11初始化管理器", e.lan);
        e.init(),
            e.setFont(this.fonts[g[e.lan]]),
            c.Audio.init(), u.Report.init(), this.initBMS(), this.initStopDebug()
    }, m.prototype.initStopDebug = function() {}, m.prototype.initEvent = function() {}, m.prototype.initBMS = function() {
        var e = d.Platform.getConfig().version;
        d.Platform.is(s.EPlatform.IOS) && (e = jsb.reflection.callStaticMethod("AppController", "gainIOSBMSVersion"), console.log("获得版本号", e)),
            x.BMS.init(d.Platform.getConfig().flag, e, function() { d.Platform.is(s.EPlatform.IOS) && x.BMS.checkKey("isAdsTrack") && jsb.reflection.callStaticMethod("AppController", "gainGameState:", 1), l.Event.emit(a.default.ENTER_MAIN) })
    }, r([t(cc.Node)], m.prototype, "loading", void 0), r([t([cc.TTFFont])], m.prototype, "fonts", void 0), r([e], m));

function m() { var e = null !== y && y.apply(this, arguments) || this; return e.loading = null, e.fonts = [], e }
n.default = e